<?php
/**
 * Created by JetBrains PhpStorm.
 * User: Administrator
 * Date: 11-6-30
 * Time: 上午10:16
 * To change this template use File | Settings | File Templates.
 */

class Mail_Period
{
    CONST PERIOD_TYPE_DAY = 1,
    PERIOD_TYPE_WORKDAY = 2,
    PERIOD_TYPE_RESTDAY = 3,
    PERIOD_TYPE_MONDAY = 4,
    PERIOD_TYPE_TUESDAY = 5,
    PERIOD_TYPE_WEDNESDAY = 6,
    PERIOD_TYPE_THURSDAY = 7,
    PERIOD_TYPE_FRIDAY = 8,
    PERIOD_TYPE_SATURDAY = 9,
    PERIOD_TYPE_SUNDAY = 10;

    static function period_types()
    {
        return array(
            self::PERIOD_TYPE_DAY,
            self::PERIOD_TYPE_WORKDAY,
            self::PERIOD_TYPE_RESTDAY,
            self::PERIOD_TYPE_MONDAY,
            self::PERIOD_TYPE_TUESDAY,
            self::PERIOD_TYPE_WEDNESDAY,
            self::PERIOD_TYPE_THURSDAY,
            self::PERIOD_TYPE_FRIDAY,
            self::PERIOD_TYPE_SATURDAY,
            self::PERIOD_TYPE_SUNDAY,
        );
    }

    static function workDays()
    {
        return array(1, 2, 3, 4, 5);
    }

    static function restDays()
    {
        return array(0, 6);
    }
}
